
#ifndef _XGRAPH_H_
#define _XGRAPH_H_



#include "xtypes.h"

typedef struct {
	int_t vertex_amt;
	int_t * vertics;
	int_t * edges;
	int_t * tags;
}graph_t, *pgraph_t;




pgraph_t graph_create( lpcstr_t szConfig );
xResult graph_release( pgraph_t p_graph );





void graph_ergod_DepthFirst( pgraph_t p_graph, int_t nBeginVertexIndex );
void graph_init( pgraph_t p_graph );
void graph_print( pgraph_t p_graph );
int_t graph_find_free_vertex( pgraph_t p_graph, int_t n_vi );
void graph_do_vertex_action( pgraph_t p_graph, int_t n_vi, int_t n_last_vi );
void graph_update_interfacing_vertex( pgraph_t p_graph, int_t n_vi );
int_t * graph_get_edge( pgraph_t p_graph, int_t si, int_t di );


#endif //_XGRAPH_H_